#ifndef lib_init_H
#define lib_init_H

#include <string>

#include "db.h"
#include "db_op.h"

class TableCreator {
protected:
    Database* db;
    Database_Operater* operater;
public:
    TableCreator(Database* db) : db(db) {
        operater = new Libaray_Operater();
    };
    ~TableCreator() {
        delete operater;
    }

    bool table_exists(const std::string& table_name);
    void create_table(const std::string& table_name, const std::string& create_sql);
};

class LibraryTableCreator : public TableCreator {
public:
    LibraryTableCreator(Database* db) : TableCreator(db) {};
    bool LibarayTableInit();
};



#endif